# coding=utf-8
__author__ = 'liubin'

# 命令行模式
from flask.ext.script import Manager
from project import app, init_db

manager = Manager(app)

@manager.command
def run():
    app.run(host=app.config['HOST'], port=app.config['PORT'])

@manager.command
def init():
    init_db()

if __name__ == "__main__":
    manager.run()